package com.yuanjin.models;

import java.util.ArrayList;

import android.os.Parcel;
import android.os.Parcelable;

public class Map_Station implements Parcelable {
	private String name;
	private String addr;
	private String area;
	private String brand;
	private double lat;// 纬度
	private double lon;// 经度
	private int distance;// 范围
	private ArrayList<Map_Petrol> gastPriceList;
	private ArrayList<Map_Petrol> priceList;

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getAddr() {
		return addr;
	}

	public void setAddr(String addr) {
		this.addr = addr;
	}

	public String getArea() {
		return area;
	}

	public void setArea(String area) {
		this.area = area;
	}

	public String getBrand() {
		return brand;
	}

	public void setBrand(String brand) {
		this.brand = brand;
	}

	public double getLat() {
		return lat;
	}

	public void setLat(double lat) {
		this.lat = lat;
	}

	public double getLon() {
		return lon;
	}

	public void setLon(double lon) {
		this.lon = lon;
	}

	public int getDistance() {
		return distance;
	}

	public void setDistance(int distance) {
		this.distance = distance;
	}

	public ArrayList<Map_Petrol> getGastPriceList() {
		return gastPriceList;
	}

	public void setGastPriceList(ArrayList<Map_Petrol> gastPriceList) {
		this.gastPriceList = gastPriceList;
	}

	public ArrayList<Map_Petrol> getPriceList() {
		return priceList;
	}

	public void setPriceList(ArrayList<Map_Petrol> priceList) {
		this.priceList = priceList;
	}

	@Override
	public int describeContents() {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(name);
		dest.writeString(addr);
		dest.writeString(area);
		dest.writeString(brand);
		dest.writeDouble(lat);
		dest.writeDouble(lon);
		dest.writeInt(distance);
		dest.writeList(gastPriceList);
		dest.writeList(priceList);		
	}
	
	public static final Parcelable.Creator<Map_Station> CREATOR=new Creator<Map_Station>() {
		
		@Override
		public Map_Station[] newArray(int size) {
			// TODO Auto-generated method stub
			return null;
		}
		
		@Override
		public Map_Station createFromParcel(Parcel source) {
			Map_Station s = new Map_Station();
			s.name = source.readString();
			s.addr = source.readString();
			s.area = source.readString();
			s.brand = source.readString();
			s.lat = source.readDouble();
			s.lon = source.readDouble();
			s.distance = source.readInt();
			s.gastPriceList = source.readArrayList(Map_Petrol.class.getClassLoader());
			s.priceList=source.readArrayList(Map_Petrol.class.getClassLoader());
			return s;
		}
	};

}
